<template>
  <CloudButton type="primary" @click="openMessage">
    Open the message box
  </CloudButton>
</template>
<script>
const key = 'updatable';
export default {
  title: '5.更新消息内容',
  methods: {
    openMessage() {
      this.$cloudMessage.loading({ content: 'Loading...', key });
      setTimeout(() => {
        this.$cloudMessage.success({ content: 'Loaded!', key, duration: 2 });
      }, 1000);
    },
  },
};
</script>